<!DOCTYPE html>
<html lang="zh-CN">
<head>
	<meta charset="UTF-8">
	<title>{echo:$this->_siteConfig->name}</title>
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	{js:jquery}
	{js:form}
	{js:validate}
	{js:dialog}
	{js:artTemplate}
	<!--[if IE]><script src="{theme:javascript/html5.js}"></script><![endif]-->
	<script src="{theme:javascript/common.js}"></script>
	<script src='{theme:javascript/site.js}'></script>
	<!-- <link rel="stylesheet" href="{skin:bubugao/css/public.css}"> -->
	<link rel="stylesheet" href="{skin:style/style.css}">
</head>
<body>

<div class="header_top">
	<div class="web">
		<div class="welcome">
			欢迎您来到 {echo:$this->_siteConfig->name}！
			{if:$this->user}
				<a href="{url:/ucenter/index}">个人中心</a>
				<a href="{url:/simple/logout}">退出</a>
			{else:}
				<a href="{url:/simple/login}">登录</a>
				<a class="reg" href="{url:/simple/reg}">免费注册</a>
			{/if}
		</div>
		<div class="header_cart" name="mycart">
			<a href="{url:/simple/cart}" class="go_cart">
				<i class="icon-shopping-cart"></i>
				购物车（<em class="count" name="mycart_count"]>0</em>）
			</a>
			<div class="cart_simple" id="div_mycart"></div>
		</div>
		<!--购物车模板 开始-->
		<script type='text/html' id='cartTemplete'>
		<div class='cart_panel'>
			<ul class='cart_list'>
				<%for(var item in goodsData){%>
				<%var data = goodsData[item]%>
				<li id="site_cart_dd_<%=item%>">
					<em>共<%=data['count']%>件</em>
					<a target="_blank" href="{url:/site/products/id/<%=data['goods_id']%>}">
						<img src="{webroot:<%=data['img']%>}">
						<h5><%=data['name']%></h5>
					</a>
					<span>￥ <%=data['sell_price']%></span>
					<del onclick="removeCart('<%=data['id']%>','<%=data['type']%>');$('#site_cart_dd_<%=item%>').hide('slow');">删除</del>
				</li>
				<%}%>
				<%if(goodsCount){%>
				<div class="cart_total">
					<p>共<span name="mycart_count"><%=goodsCount%></span>件商品</p>
					<p>商品总额：<em name="mycart_sum">￥<%=goodsSum%></em></p>
					<a href="{url:simple/cart}">去购物车结算</a>
				</div>
				<%}else{%>
				<div class='cart_no'>购物车空空如也~</div>
				<%}%>
			</ul>
		</div>
		</script>
		<ul class="top_tool">
			<li><a href="{url:ucenter/index}">个人中心</a></li>
			{if:$this->user}
			<li><a href="{url:/simple/seller}">申请开店</a></li>
			{/if}
			<li><a href="{url:/seller/index}">商家管理</a></li>
			<li><a href="{url:/site/help_list}">使用帮助</a></li>
		</ul>
	</div>
</div>
<header class="header web">
	<nav class="header_nav">
		<div class="goods_nav">
			<h1 class="logo">
				<!-- 这里的LOGO图片会自动靠左居中.因此只需要制作一个透明的LOGO图片即可 LOGO最大尺寸 200*90 -->
				<a href="{url:}">
					<img src="{if:$this->_siteConfig->logo}{webroot:$this->_siteConfig->logo}{else:}{skin:image/logo.png}{/if}">
				</a>
			</h1>
			<ul class="cat_list none">
				{foreach:items=Api::run('getCategoryListTop')  item=$first}
				<li>
					<h3><a href="{url:/site/pro_list/cat/$first[id]}">{$first['name']}</a></h3>
					<div class="cat_more">
						<ul>
							{foreach:items=Api::run('getCategoryExtendList',array('#categroy_id#',$first['id']),24)}
							<li>
								<a href="{url:/site/products/id/$item[id]}" target="_blank" title="{$item['name']}">
									<img class="img-lazyload" src="{url:/pic/thumb/img/$item[img]/w/40/h/40}" alt="{$item['name']}">
									<strong>{$item['name']}</strong>
									<em>选购</em>
								</a>
							</li>
							{/foreach}
						</ul>
					</div>
				</li>
				{/foreach}
			</ul>
		</div>
		<ul class="site_nav">
			<li><a href="{url:/site/index}">首页</a></li>
			{foreach:items=Api::run('getGuideList')}
			<li><a href="{url:$item[link]}">{$item['name']}</a></li>
			{/foreach}
		</ul>
	</nav>
	<div class="header_search">
		<form method='get' action='{url:/}'>
			<input type='hidden' name='controller' value='site'>
			<input type='hidden' name='action' value='search_list'>
			<div class="search_box">
				<input class="input_keywords" type="text" name='word' autocomplete="off" placeholder="输入关键词">
				<label class="input_submits">
					<input type="submit" value="">
					<i class="icon-search"></i>
				</label>
			</div>
		</form>
		<div class="hot_words">
			{foreach:items=Api::run('getKeywordList',2) }
			{set:$tmpWord = urlencode($item['word']);}
			<a href="{url:/site/search_list/word/$tmpWord}">{$item['word']}</a>
			{/foreach}
		</div>
	</div>

</header>

<div class="bigweb">
	<section class="breadcrumb">
		<span>您当前的位置：</span> <a href="{url:}">首页</a> » <a href="{url:/ucenter/index}">我的账户</a>
	</section>


	<section class="web">
		<section class="main">
			{viewcontent}
		</section>
		<aside class="bar">
			{set:$index=0;}
			{foreach:items=menuUcenter::init()}
			{set:$index++;}
			<nav class="user_bar">
				<h3>{$key}</h3>
				<ul>
					{foreach:items=$item key=$moreKey item=$moreValue}
					<li><a title="{$moreValue}" href="{url:$moreKey}">{$moreValue}</a></li>
					{/foreach}
				</ul>
			</nav>
			{/foreach}
		</aside>
	</section>
</div>
<footer class="foot">
	<section class="service">
		<ul>
			<li class="item1">
				<i class="icon-star"></i>
				<strong>正品优选</strong>
			</li>
			<li class="item2">
				<i class="icon-globe"></i>
				<strong>上市公司</strong>
			</li>
			<li class="item3">
				<i class="icon-group"></i>
				<strong>300家连锁门店</strong>
			</li>
			<li class="item4">
				<i class="icon-plane"></i>
				<strong>长株潭次日达</strong>
			</li>
			<li class="item5">
				<i class="icon-gift"></i>
				<strong>满99包邮</strong>
			</li>
		</ul>
	</section>
	<section class="help">
		{set:$catIco = array('help-new','help-delivery','help-pay','help-user','help-service')}
		{foreach:items=Api::run('getHelpCategoryFoot') item=$helpCat}
		<dl class="help_{echo:$key+1}">
			<dt>{$helpCat['name']}</dt>
			{foreach:items=Api::run('getHelpListByCatidAll',array('#cat_id#',$helpCat['id']))}
			<dd><a href="{url:/site/help/id/$item[id]}">{$item['name']}</a></dd>
			{/foreach}
		</dl>
		{/foreach}
		<div class="contact">
			<em>400-888-8888</em>
			<span>周一到周日 8:00-18:00</span>
			<span>（仅收市话费）</span>
			<a href="#"><i class="icon-comments"></i> 24小时在线客服</a>
		</div>
	</section>
	<section class="copy">
		{echo:IFilter::stripSlash($this->_siteConfig->site_footer_code)}
	</section>
</footer>



<script>
//DOM加载完毕后运行
$(function(){
	//隔行换色
	$(".list_table tr:nth-child(even)").addClass('even');
	$(".list_table tr").hover(
		function () {
			$(this).addClass("sel");
		},
		function () {
			$(this).removeClass("sel");
		}
	);

	//按钮高亮
	var localUrl = "{echo:IUrl::getUri()}";
	$('a[href^="'+localUrl+'"]').parent().addClass('current');
});
</script>
</body>
</html>
